package com.itheima.mapper;

import com.itheima.pojo.Student;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

@Mapper
public interface StudentMapper {

    List<Student> queryAllStudent(@Param("name") String name, @Param("degree") Integer degree, @Param("clazzId") Integer clazzId);

    void deleteStudent(@Param("ids") List<Integer> ids);

    void insertStudent(Student student);

    Student queryStudentById(Integer id);

    void updateStudent(Student student);

    void updateStudentViolation(@Param("id") Integer id, @Param("score") Short score);

    List<Map<String, Object>> calcStudentDegreeData();

    List<Map<String, Object>> calcStudentDegreeData2();
}
